package com.kgc.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * @Author：周申宇 <p>
 * @Date:2021/6/19 16:04
 * <p>
 * @Decription:
 */
@Component
@ConfigurationProperties(prefix = "buy.limit")
@Data
public class BuyLimitConfig {

    /**
     * 抢购初始库存数量
     */
    private Integer prodStockNum;

    /**
     * 商品库存前缀
     */
    private String stockNumPrefix;
    /**
     * 锁定用户的前缀
     */
    private String lockUserPrefix;
    /**
     * 锁定用户的时长
     */
    private long buyLimitTime;

    /**
     * 锁定商品库存前缀标识
     */
    private String stockLockPrefix;
    /**
     * 锁库存时长
     */
    private long stockLockTime;
}
